//公共接口js文件
import request from '@/common/requst.js' //引进requst方法
//获取验证码接口
export const code = (data) => {
	return request({
		url: '/sms/public/sendCode',
		method: 'post',
		data
	})
}
//用户登录接口
export const login = (data) => {
	return request({
		url: '/user/userInfo/public/phoneLogin',
		method: 'post',
		data
	})
}
//选择职业接口
export const occupation = (data) => {
	return request({
		url: '/universal/userUpdate',
		method: 'post',
		data
	})
}

//  好物&首页-列表
export const notes = (data) => {
	return request({
		url: '/user/tabBar/public/article/list',
		method: 'post',
		data
	})
}
// 发现-二级导航栏
export const navList = (data) => {
	return request({
		url: '/system/sysClassification/public/list',
		method: 'post',
		data
	})
}
// 好物&首页详情-登录
export const notesDetail = (data) => {
	return request({
		url: '/universal/article/details',
		method: 'post',
		data
	})
}

// 项目笔记详情
export const notesDetails = (data) => {
	return request({
		url: '/universal/ProjectNotes/details',
		method: 'post',
		data
	})
}

// tabber工厂首页list列表
export const details = (data) => {
	return request({
		url: '/user/tabBar/public/plantList',
		method: 'post',
		data
	})
}
// 首页监控接口
export const videoUrl = (data) => {
	return request({
		url: '/universal/public/url',
		method: 'post',
		data
	})
}
// 微信登录接口
export const weiloing = (data) => {
	return request({
		url: '/wx/ma/user/public/appLogin',
		method: 'post',
		data
	})
}
// 聊天接口
export const chat = (data, url) => {
	return request({
		url: url,
		method: 'post',
		data
	})
}
// 聊天消息列表接口
export const chatIndex = (data) => {
	return request({
		url: '/universal/getMsgList',
		method: 'post',
		data
	})
}
//个人信息获取接口
export const person = (data) => {
	return request({
		url: '/universal/myInfo',
		method: 'post',
		data
	})
}

// 其他用户详情接口
export const otherPerson = (data) => {
	return request({
		url: '/universal/userInfo',
		method: 'post',
		data
	})
}
//聊天页面历史消息接口
export const history = (data) => {
	return request({
		url: '/universal/chatDetail',
		method: 'post',
		data
	})
}
//上传接口
export const updta = (data) => {
	return request({
		url: '/universal/uploadCloud',
		method: 'post',
		data
	})
}
//切换角色接口
export const role = (data) => {
	return request({
		url: '/universal/sliceLogin',
		method: 'post',
		data
	})
}
//获取另外角色接口
export const myRole = (data) => {
	return request({
		url: '/universal/myRole',
		method: 'post',
		data
	})
}
//报价单详情
export const quotationDetail = (data) => {
	return request({
		url: '/universal/quotationDetail',
		method: 'post',
		data
	})
}
//报价单列表
export const quotationList = (data) => {
	return request({
		url: '/universal/quotationList',
		method: 'post',
		data
	})
}
//添加笔记
export const add = (data) => {
	return request({
		url: '/universal/article/add',
		method: 'post',
		data
	})
}
//我的订单列表
export const designerInfoMe = (data) => {
	return request({
		url: '/designer/designerInfo/projectList',
		method: 'post',
		data
	})
}
// 我的项目-查看订单-设计师账号
export const projectDetailDesigner = (data) => {
	return request({
		url: '/designer/designerInfo/detail',
		method: 'post',
		data
	})
}
//我的订单列表详情
export const projectDetailMe = (data) => {
	return request({
		url: '/user/userProjectOrder/detail',
		method: 'post',
		data
	})
}
//我的项目列表-查看订单接口-设计师
export const projectNote = (data) => {
	return request({
		url: '/user/tabBar/public/designer/projectNote/list',
		method: 'post',
		data
	})
}
// 我的项目列表详情-设计师
export const projectNoteDetails = (data) => {
	return request({
		url: '/user/tabBar/public/designer/projectNote/details',
		method: 'post',
		data
	})
}
//我的项目列表接口-用户
export const projectList = (data) => {
	return request({
		url: '/user/userProjectOrder/projectList',
		method: 'post',
		data
	})
}

//进行中项目接口
export const getProjectList = (data) => {
	return request({
		url: '/universal/getProjectList',
		method: 'post',
		data
	})
}
//找安装列表接口
export const installList = (data) => {
	return request({
		url: '/user/tabBar/public/installList',
		method: 'post',
		data
	})
}
//工厂二级页面产品列表接口-登陆
export const goodsList = (data) => {
	return request({
		url: '/universal/gcDetailsAuto',
		method: 'post',
		data
	})
}
//工厂二级页面产品列表接口-不登陆
export const goodsPublicList = (data) => {
	return request({
		url: '/user/tabBar/public/gcDetailsAuto',
		method: 'post',
		data
	})
}
// 设计师、安装师傅、工厂入驻审核
export const applications = (data) => {
	return request({
		url: '/universal/submit/applications',
		method: 'post',
		data
	})
}
// 系统消息
export const systemMessages = (data) => {
	return request({
		url: '/system/sysInformation/list',
		method: 'post',
		data
	})
}
// gpt首次登录动画
export const hasReplayGpt = (data) => {
	return request({
		url: '/user/tabBar/public/hasReplayGpt',
		method: 'post',
		data
	})
}
// gpt调用接口
export const gpt = (data) => {
	return request({
		url: '/universal/public/aiChat',
		method: 'post',
		timeout: 1500000,
		data
	})
}
// gpt历史聊天
export const historyGpt = (data) => {
	return request({
		url: '/user/tabBar/public/hasGetGptHistory',
		method: 'post',
		data
	})
}
// 判断是否收藏-未登录
export const visitorCollect = (data) => {
	return request({
		url: '/universal/tabBar/public/goodsDetails',
		method: 'post',
		data
	})
}
// 判断是否收藏-登录
export const loginCollect = (data) => {
	return request({
		url: '/universal/tabBar/goodsDetailsAuto',
		method: 'post',
		data
	})
}
// h5支付宝支付接口
export const h5ScanPay = (data) => {
	return request({
		url: '/public/alipay/h5ScanPay',
		method: 'get',
		timeout: 1500000,
		data
	})
}
// 报价单支付接口
export const subOrder = (data) => {
	return request({
		url: '/user/userProjectOrder/subOrder',
		method: 'post',
		data
	})
}
// 报价单暂不支付接口
export const subOrderBp = (data) => {
	return request({
		url: '/user/userProjectOrder/subOrderBp',
		method: 'post',
		data
	})
}
// 话题列表
export const topics = (data) => {
	return request({
		url: '/system/sysTopic/public/list',
		method: 'post',
		data
	})
}
// 帮助列表
export const helpList = (data) => {
	return request({
		url: '/universal/feedbackList',
		method: 'post',
		data
	})
}
// 反馈列表
export const feedbackList = (data) => {
	return request({
		url: '/universal/feedback/contentList',
		method: 'post',
		data
	})
}
// 添加反馈
export const addFeedback = (data) => {
	return request({
		url: '/universal/feedback/content',
		method: 'post',
		data
	})
}
// 发送图纸
export const drawing = (data) => {
	return request({
		url: '/designer/project/sendDrawing',
		method: 'post',
		data
	})
}
//  消息详情
export const sysInformationDetails = (data) => {
	return request({
		url: '/system/sysInformation/details',
		method: 'post',
		data
	})
}
//  判断是否发送了安装邀请
export const projectHasRepeat = (data) => {
	return request({
		url: '/universal/projectHasRepeat',
		method: 'post',
		data
	})
}
//  判断当前用户职业
export const myCurrentRole = (data) => {
	return request({
		url: '/universal/myCurrentRole',
		method: 'post',
		data
	})
}
// 工厂报价
export const factoryQuotation = (data) => {
	return request({
		url: '/factory/gcDrawing/factory',
		method: 'post',
		data
	})
}

//安装师傅-我的预约
export const reservation = (data) => {
	return request({
		url: '/install/installInfo/myAgreement',
		method: 'post',
		data
	})
}
//成员搜索接口
export const chatSearch = (data) => {
	return request({
		url: '/universal/chatSearch',
		method: 'post',
		data
	})
}
//创建群聊
export const createGroup = (data) => {
	return request({
		url: '/system/sysGroupPerson/createGroup',
		method: 'post',
		data
	})
}
//聊天信息
export const messageCenter = (data) => {
	return request({
		url: '/system/sysGroupPerson/messageCenter',
		method: 'post',
		data
	})
}
//修改项目名称-群聊
export const projectName = (data) => {
	return request({
		url: '/universal/projectName',
		method: 'post',
		data
	})
}
//修改我的名字-群聊
export const chatName = (data) => {
	return request({
		url: '/universal/chatName',
		method: 'post',
		data
	})
}
//项目群聊设置-群聊
export const groupChat = (data) => {
	return request({
		url: '/universal/groupChat',
		method: 'post',
		data
	})
}
//退出群聊-群聊
export const deleteChat = (data) => {
	return request({
		url: '/universal/deleteChat',
		method: 'post',
		data
	})
}
//邀请新成员-群聊
export const saveChat = (data) => {
	return request({
		url: '/universal/saveChat',
		method: 'post',
		data
	})
}

//群聊历史记录
export const messageHistory = (data) => {
	return request({
		url: '/system/sysGroupPerson/messageHistory',
		method: 'post',
		data
	})
}
//消息中心已读未读
export const readMessage = (data) => {
	return request({
		url: '/system/sysGroupChat/readMessage',
		method: 'post',
		data
	})
}